package com.sprboot.demo;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

/**
 * http://start.spring.io/ spring boot的优点： 自动化配置，快速创建spring项目 自动解决maven依赖
 * 内嵌tomcat,jetty容器
 * 
 * java -jar xx.jar --server.port=8090
 * 
 * @author yangli
 * 
 */
@SpringBootApplication
public class DemoApplication {

	public static void main(String[] args) {
		SpringApplication.run(DemoApplication.class, args);
	}
	

//	@Bean
//	public CommandLineRunner commandLineRunner(ApplicationContext ctx) {
//		return args -> {
//
//			System.out.println("Let's inspect the beans provided by Spring Boot:");
//
//			String[] beanNames = ctx.getBeanDefinitionNames();
//			Arrays.sort(beanNames);
//			for (String beanName : beanNames) {
//				System.out.println("===>" + beanName);
//			}
//
//		};
//	}
}
